package com.parkinglot.service;


import com.parkinglot.parmeter.AdvertaddParm;
import com.parkinglot.parmeter.AdvertqueryParm;
import com.parkinglot.parmeter.AdvertupdParm;
import com.parkinglot.pojo.Advert;
import com.parkinglot.vo.AdvertCountVo;
import com.parkinglot.vo.AdvertqueryVo;

import java.util.List;

/**
 * (Advert)表服务接口
 *
 * @author makejava
 * @since 2020-11-13 14:50:52
 */
public interface AdvertService {

    /**
     * 通过ID查询单条数据
     *
     * @param id 主键
     * @return 实例对象
     */
    Advert queryById(Integer id);

    /**
     * 查询多条数据
     *
     * @param offset 查询起始位置
     * @param limit  查询条数
     * @return 对象列表
     */
    List<Advert> queryAllByLimit(int offset, int limit);

    /**
     * 新增数据
     *
     * @param advert 实例对象
     * @return 实例对象
     */
    Advert insert(Advert advert);

    /**
     * 修改数据
     *
     * @param advertupdParm 实例对象
     * @return 实例对象
     */
    int update(AdvertupdParm advertupdParm);

    /**
     * 通过主键删除数据
     *
     * @param id 主键
     * @return 是否成功
     */
    boolean deleteById(Integer id);

   // int addadvert(AdvertaddParm advertaddParm, MultipartFile[] files, HttpServletRequest request);
    int addadvert(AdvertaddParm advertaddParm);

    /**
     * 广告位统计（统计哪个车库哪个广告位访问次数及时间段信息）
     * @return
     */
    List<AdvertCountVo> countadvertnum();


    List<AdvertCountVo> garageadverdjv(AdvertqueryParm advertqueryParm);

    List<AdvertqueryVo> advertpagerecord(AdvertqueryParm advertqueryParm);

    List<AdvertCountVo> advertweekdjv(AdvertqueryParm advertqueryParm);

    List<AdvertCountVo> advertmonthdjv(AdvertqueryParm advertqueryParm);

    List<AdvertCountVo> allgaragezrdjv();

    List<AdvertCountVo> allgarageszdjv();

    List<AdvertCountVo> allgaragesydjv();
}